package org.dormnet.dao.mapping;

import java.sql.ResultSet;
import java.sql.SQLException;
import java.util.Date;

import org.dormnet.dao.bean.Dormnews;

public class DormnewsMapping implements BeanMapping {
	
	public Object mapping(ResultSet resultSet) throws SQLException {
		Dormnews dormnews = new Dormnews();
		dormnews.setDormid(resultSet.getInt("dormid"));
		dormnews.setIsdeleted(resultSet.getInt("isdeleted"));
		dormnews.setNews(resultSet.getString("news"));
		dormnews.setDnId(resultSet.getInt("DnId"));
		dormnews.setStudentid(resultSet.getString("studentid"));
		dormnews.setPtime(resultSet.getDate("ptime"));
		return dormnews;
	}

}
